# nginx configuration

location / {
  if (!-e $request_filename){
    rewrite ^/(.*).(html|pdf|csv|txt|json)$ /?slug=$1&format=$2;
  }
}